﻿
<%@ Page Language="C#" AutoEventWireup="true" MasterPageFile="../MasterPage.Master"
    CodeBehind="wfIngresoSubsidioMnt.aspx.cs" Inherits="RH.wfIngresoSubsidioMnt" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="ajax" %>
<%@ Import Namespace="Texfina.Common.Mg" %>
<%@ Import Namespace="Texfina.Core.Common" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
    <link href="../Styles/jquery-ui.custom.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript">
        window.onload = function () {
            var menuTable = document.getElementById('<%=mnuToolbar.ClientID %>');
            var menuLinks = menuTable.getElementsByTagName("a");
            if (menuLinks != null) {
                switch (menuLinks.length) {
                    case 2:
                        menuLinks[0].onclick = function () { return validateEditForm('_BTTSAVE') }
                        break;

                    case 3:
                        menuLinks[0].onclick = function () { return validateEditForm('_BTTSAVE') }
                        menuLinks[1].onclick = function () { return validateEditForm('_BTTSAVNEW') }
                        break;
                }
            }
                    
            this.ResizeGrid();
            this.MessageOnPostback();
        }
        
        function ResizeGrid() {
        }

        function ActiveCalcular() {
            document.getElementById('<%=hdnstCalcular.ClientID %>').value = '<%=ConstFlagEstado.ACTIVADO %>';
        }

        function ActiveNuProceCal() {
            ActiveCalcular();
            document.getElementById('<%=hdnstNuProceCal.ClientID %>').value = '<%=ConstFlagEstado.ACTIVADO %>';
        }

        function panelOnUpdating() {
            updatePanelAnimationUpdating();
        }

        function panelOnUpdated() {
            ResizeGrid();
            updatePanelAnimationUpdated();
        }
    </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
    <div class="ToolBar">
        <asp:Menu ID="mnuToolbar" runat="server" Orientation="Horizontal" CssClass="ToolBarControl"
            OnMenuItemClick="mnuToolbar_MenuItemClick">
            <Items>
                <asp:MenuItem Text="Guardar" Value="_BTTSAVE" ImageUrl="../Images/Icons/Enabled/SAVE.png">
                </asp:MenuItem>
                <asp:MenuItem Text="Salir" Value="_BTTEXIT" ImageUrl="../Images/Icons/Enabled/BACK.png">
                </asp:MenuItem>
            </Items>
        </asp:Menu>
    </div>
        <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <ContentTemplate>
    <div class="DataHeader">
        <table id="TableDataHeader" cellpadding="0" cellspacing="0">
            <tr>
                <td colspan="3">
                    &nbsp;
                </td>
            </tr>
            <tr>
                <td style="width: 5px">
                    &nbsp;
                </td>
                <td>
                    <div style="border: 1px solid #ccc; border-radius: 5px; -moz-border-radius: 5px;
                        -webkit-border-radius: 5px; -ms-border-radius: 5px;">
                        <table width="100%" cellpadding="0" cellspacing="2">
                            <tr>
                                <td colspan="13">
                                    &nbsp;
                                </td>
                            </tr>
                            <tr>
                                <td style="width: 5px;">
                                    &nbsp;
                                </td>
                                <td style="width: 200px;">
                                    Cod. Subsidio
                                </td>
                                <td colspan="10">
                                    <esd:esdMaskedTextBox runat="server" ID="txtidSubsidio" Width="100px" Mask="9999">
                                    </esd:esdMaskedTextBox>
                                </td>
                                <td style="width: 5px;">
                                    &nbsp;
                                </td>
                            </tr>
                            <tr>
                                <td style="width: 5px;">
                                    &nbsp;
                                </td>
                                <td>
                                    Personal
                                </td>
                                <td colspan="6">
                                    <esd:esdButtonTextBox runat="server" ID="txtidPersonal" Width="280px"></esd:esdButtonTextBox>
                                </td>
                                <td style="width: 30px;">
                                    &nbsp;
                                </td>
                                <td>
                                    Tipo de Subsidio
                                </td>
                                <td colspan="2">
                                    <asp:DropDownList runat="server" ID="ddlidTipoSubsidio" Width="180px"></asp:DropDownList>
                                </td>
                                <td style="width: 5px;">
                                    &nbsp;
                                </td>
                            </tr>
                            <tr>
                                <td colspan="13">
                                    &nbsp;
                                </td>
                            </tr>
                            <tr>
                                <td style="width: 5px;">
                                    &nbsp;
                                </td>
                                <td>
                                    Fecha Subsidio
                                </td>
                                <td colspan="10">
                                    <esd:esdDateTextBox ID="txtfeSubsidio" runat="server" Width="100px"></esd:esdDateTextBox>
                                </td>
                                <td style="width: 5px;">
                                    &nbsp;
                                </td>
                            </tr>
                            <tr>
                            <td style="width: 5px;">
                                    &nbsp;
                                </td>
                                <td>
                                    Fecha Inicio Periodo Incapacidad
                                </td>
                                <td colspan="10">
                                    <esd:esdDateTextBox ID="txtfeInicio" runat="server" Width="100px"></esd:esdDateTextBox>
                                </td>
                                <td style="width: 5px;">
                                    &nbsp;
                                </td>
                            </tr>
                            <td style="width: 5px;">
                                    &nbsp;
                                </td>
                                <td>
                                    Fecha Fin Periodo Incapacidad
                                </td>
                                <td colspan="10">
                                    <esd:esdDateTextBox ID="txtfeFin" runat="server" Width="100px"></esd:esdDateTextBox>
                                </td>
                                <td style="width: 5px;">
                                    &nbsp;
                                </td>
                            </tr>
                            <tr>
                                <td colspan="13">
                                    &nbsp;
                                </td>
                            </tr>
                            <tr>
                                <td style="width: 5px;">
                                    &nbsp;
                                </td>
                                <td>
                                    Planilla
                                </td>
                                <td colspan="2">
                                    <esd:esdButtonTextBox ID="txtidPlanilla" runat="server" Width="280px">
                                    </esd:esdButtonTextBox>
                                </td>
                                <td style="width: 5px;">
                                    &nbsp;
                                </td>
                                <td>
                                    Forma pago
                                </td>
                                <td colspan="2">
                                    <esd:esdTextBox ID="txtidForPago" runat="server" Width="180px"></esd:esdTextBox>
                                </td>
                                <td style="width: 30px;">
                                    &nbsp;
                                </td>
                                <td>
                                    Nro Proceso Inicial
                                </td>
                                <td colspan="2">
                                    <esd:esdTextBox ID="txtnuProcAnual" runat="server" Width="100px"></esd:esdTextBox>
                                </td>
                                <td style="width: 5px;">
                                    &nbsp;
                                </td>
                            </tr>
                            <tr>
                                <td style="width: 5px;">
                                &nbsp;
                                </td>
                                <td>
                                    Observación
                                </td>
                                <td colspan="10">
                                    <esd:esdTextBox ID="txtdsObservacion" runat="server" TextMode="MultiLine" Height="45px" Width="100%"></esd:esdTextBox>
                                </td>
                                <td style="width: 5px;">
                                    &nbsp;
                                </td>
                            </tr>
                            <tr>
                                <td colspan="13">
                                    &nbsp;
                                </td>
                            </tr>
                        </table>
                    </div>
                </td>
                <td style="width: 5px">
                    &nbsp;
                </td>
            </tr>
            <tr>
                <td colspan="3">
                    &nbsp;
                </td>
            </tr>
        </table>
    </div>
    <div class="DataDetail">
        
    </div>

    <asp:HiddenField ID="hdnMsgOPB" runat="server" />
    <asp:HiddenField ID="hdnidPersonal" runat="server" />
    <asp:HiddenField ID="hdnidPlanilla" runat="server" />
    <asp:HiddenField ID="hdnidForPago" runat="server" />
    <asp:HiddenField ID="hdnstCalcular" runat="server" />
    <asp:HiddenField ID="hdnstNuProceCal" runat="server" />
    <asp:HiddenField ID="hdnidPlanillaPp" runat="server" />
    <asp:HiddenField ID="hdnidForPagoPp" runat="server" />

 </ContentTemplate> 
</asp:UpdatePanel>
<ajax:UpdatePanelAnimationExtender ID="upae" BehaviorID="animation" runat="server"
    TargetControlID="updatePanel1">
    <animations>
        <OnUpdating>
        <Parallel duration="0.5">
            <ScriptAction Script="panelOnUpdating();" />  
        </Parallel>
        </OnUpdating>
        <OnUpdated>
        <Parallel duration="0.5">
            <ScriptAction Script="panelOnUpdated();" /> 
        </Parallel> 
        </OnUpdated>
    </animations>
</ajax:UpdatePanelAnimationExtender>
<div id="updateProgressDiv" class="updateProgress" style="display: none">
        <table width="100%">
            <tr>
                <td valign="middle">
                    <img src="../Images/Controls/Loading.gif" />
                </td>
                <td valign="middle">
                    <span class="updateProgressMessage">Cargando ...</span>
                </td>
            </tr>
        </table>
</div>
</asp:Content>
